<extend name="public/base"/>

<block name="content">

    <!--内容栏start-->

     <br/>
    <ul class="nav nav-tabs">
   <li class="active"><a href="{:U('Index/uploadLunwen')}">论文上传</a></li>
   <li><a href="{:U('Index/viewLunwen')}">浏览论文</a></li>
   </ul>
	<!-- 标题栏 -->	  
    <h4 class="center">论文上传</h4>
    <!-- 数据列表 -->      
         <table class="table data-table table-striped table-bordered">
             <thead>
            <tr class="info">                
                <th class="">序号</th>                                     
                <th class="">类别</th>
                <th class="">教师</th>
                <th class="">标题</th>                
                <th class="">文章摘要</th>
                <th class="">上传日期</th>                
                <th class="">操  作</th>
            </tr>
            </thead>
            <tbody>
            <notempty name="list">
                <volist name="list" id="vo">
                <tr>                    
                    <td>{$vo.id} </td>
                    <td>{$vo.subject}</td>
                    <td>{$vo.teacher}</td>
                    <td>{$vo.title}</td>
                    <td>{$vo.abstract|msubstr=0,20,'utf-8',true}</td>      
                    <td><span><if condition="($vo.update_time eq 0)"> &nbsp <else/>
                  {$vo.update_time|date='Y-m-d',###}</if></span></td>                        
                    <td>
                        <a href="{:U('Index/editlunwen','id='.$vo['id'])}" >编辑</a> |                        
                        <a href="{:U('Index/deletelunwen?id='.$vo['id'])}" class="authorize">删除</a>
                        
                        </td>
                </tr>
                </volist>
                <else/>
                <td colspan="8" class="text-center"> aOh! 暂时还没有内容! </td>
                </notempty>
            </tbody>
            </table>
      	
           <h3>学科论文上传 </h3>
        <form class="form-horizontal" method='post' enctype="multipart/form-data" id="formlunwen" name="formlunwen"  action="" role="form">
        <!-- {:U('Index/addHomework')} -->
           <div class="form-group ">
          <label class="col-sm-1 control-lable text-right" for="subject">类别:</label>
            <div class="col-sm-4">
                  <select name="subject" id="subject" class="form-control"  style="width:180px;">
                      <option >语文</option>
                      <option >数学</option>
                      <option >英语</option>
                      <option >科学</option>
                      <option >综合</option>  
                  </select>
              </div>
                 <label class="col-sm-2 control-lable text-right">教师:</label>            
               <div class="col-sm-4"> <input class="form-control" type="text"  name="teacher" value="" > </div>   
        　　</div>
            <div class="form-group">
                 <label class="col-sm-1 control-lable text-right">标题:</label> 
                 <div class="col-sm-10">           
                <input class="form-control" type="text"  name="title" value="" > 
                </div>   
        　　</div>

             <div class="form-group">
               <label class="col-sm-2 control-lable text-right">请选择上传文件：
               </label>
               <div class="col-sm-9"><input class="form-control" type="file"  name="upfile" /></div>
               </div>
    
         <div class="form-group">
            <label class="col-sm-offset-1 col-sm-11 control-lable">论文摘要（可不填）<span class="check-tips">（请将论文摘要复制到下面框内,然后点击下面的上传按钮完成提交。）</span></label>
            <div class="col-sm-offset-1 col-sm-10 controls">
               <textarea name="abstract" class="text input-large"></textarea>
              {:hook('adminArticleEdit', array('name'=>'abstract','value'=>$data['abstract']))}
            </div>
            </div>
      <div class="form-actions"> 
        <button type="submit" class="btn btn-primary">上传论文</button>
        <button type="button" class="btn btn-danger">取消</button>  
        </div>
      </form> 

</block>

